<template>
  <div>
    <template v-for="(item, _index) in listQueryParams">
      <template v-if="item.type === 1">
        <el-input :key="_index" class="filter-item" v-model="item.val" :placeholder="item.desc" clearable />
      </template>
    </template>
    <el-button type="primary" icon="Search" @click="initList(true)">搜索</el-button>
    <template v-if="clickAdd">
      <el-button type="primary" @click="clickAdd">添加</el-button>
    </template>
    <slot name="afterListQueryButton" :getList="initList" />
  </div>
</template>

<script setup>
defineProps({
  listQueryParams: {
    type: Array,
    default: () => []
  },
  disableFeatures: {
    type: Array,
    default: () => []
  },
  initList: {
    type: Function,
    default: () => { }
  },
  clickAdd: {
    type: Function,
    default: undefined
  }
})
</script>

<style scoped>
</style>